package com.css.zfzx.fxpg.modules.citycounty.repository;

import com.css.zfzx.fxpg.modules.citycounty.repository.entity.FxCityCountyEntity;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
 * @author leon
 * @date 2020-11-26
 */
public interface FxCityCountyRepository extends JpaRepository<FxCityCountyEntity, String> {

    /**
     * 查询所有市县名称
     *
     * @return
     */
    @Query(nativeQuery = true, value = "select city_county_name from fx_city_county")
    List<String> findCityCountyNames();
}
